import React from 'react';
import { Tag } from 'antd';
import { CrownOutlined, UserOutlined } from '@ant-design/icons';

const RoleTag = ({ role }) => {
  return role === 'admin' ? 
    <Tag color="blue" icon={<CrownOutlined />}>管理员</Tag> : 
    <Tag color="green" icon={<UserOutlined />}>成员</Tag>;
};

export default RoleTag;